package service;

import bao.BookDao;
import model.Book;

import java.util.List;

// 创建数据信息的Servcie方法
public class BookService {
    BookDao BD = new BookDao();
    //    获取图书信息
    public List<Book> SelectAllBookInformation(){
        return BD.QueryAllBookInformation();
    }
    //    删除图书信息
    public boolean DeletBookByName(String bk_name){
        return BD.DeleteBookByName(bk_name);
    }
    //    修改图书信息
    public boolean UpdateBookByName(Book book,String bk_name){return BD.UpdateBookByName(book,bk_name);}
    //    添加图书信息
    public boolean AddBookInformation(Book book){return BD.AddBookInformation(book);}
    //    根据图书名称查询图书信息
    public List<Book> QueryBookInfoByName(String bk_name){return BD.QueryBookInfoByName(bk_name);}
}
